package com.genfu.reform.model;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 * The persistent class for the USER_INFO database table.
 * 
 */
@Entity
@Table(name = "USER_INFO")
public class UserInfo implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	@Column(name = "USER_ID")
	private long id;

	@Column(name = "DEPARTMENT_ID")
	private long departmentId;

	@Column(name = "DISTRICT_ID")
	private long districtId;

	@Column(name = "USER_UPPER_ID")
	private long userUpperId;

	@Column(name = "USER_CODE")
	private String userCode;

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "USER_CREATE_DATE")
	private Date userCreateDate;

	@Column(name = "USER_DESCRIPTION")
	private String userDescription;

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "USER_EFF_DATE")
	private Date userEffDate;

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "USER_EXP_DATE")
	private Date userExpDate;

	@Column(name = "USER_FLAG")
	private String userFlag;

	@Column(name = "USER_NAME")
	private String userName;

	@Column(name = "USER_OTHERS")
	private String userOthers;

	@Column(name = "USER_PASSWORD")
	private String userPassword;

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "USER_UPDATE_DATE")
	private Date userUpdateDate;

	@ManyToMany(cascade = CascadeType.REFRESH)
	@JoinTable
	private List<RoleInfo> ROLE_INFO;

	public List<RoleInfo> getROLE_INFO() {
		return ROLE_INFO;
	}

	public void setROLE_INFO(List<RoleInfo> rOLE_INFO) {
		ROLE_INFO = rOLE_INFO;
	}

	public UserInfo() {
	}

	public long getId() {
		return this.id;
	}

	public void setId(long id) {
		this.id = id;
	}

	public long getDepartmentId() {
		return this.departmentId;
	}

	public void setDepartmentId(long departmentId) {
		this.departmentId = departmentId;
	}

	public long getDistrictId() {
		return this.districtId;
	}

	public void setDistrictId(long districtId) {
		this.districtId = districtId;
	}

	public long getUserUpperId() {
		return userUpperId;
	}

	public void setUserUpperId(long userUpperId) {
		this.userUpperId = userUpperId;
	}

	public String getUserCode() {
		return this.userCode;
	}

	public void setUserCode(String userCode) {
		this.userCode = userCode;
	}

	public Date getUserCreateDate() {
		return this.userCreateDate;
	}

	public void setUserCreateDate(Date userCreateDate) {
		this.userCreateDate = userCreateDate;
	}

	public String getUserDescription() {
		return this.userDescription;
	}

	public void setUserDescription(String userDescription) {
		this.userDescription = userDescription;
	}

	public Date getUserEffDate() {
		return this.userEffDate;
	}

	public void setUserEffDate(Date userEffDate) {
		this.userEffDate = userEffDate;
	}

	public Date getUserExpDate() {
		return this.userExpDate;
	}

	public void setUserExpDate(Date userExpDate) {
		this.userExpDate = userExpDate;
	}

	public String getUserFlag() {
		return this.userFlag;
	}

	public void setUserFlag(String userFlag) {
		this.userFlag = userFlag;
	}

	public String getUserName() {
		return this.userName;
	}

	public void setUserName(String userName) {
		this.userName = userName;
	}

	public String getUserOthers() {
		return this.userOthers;
	}

	public void setUserOthers(String userOthers) {
		this.userOthers = userOthers;
	}

	public String getUserPassword() {
		return this.userPassword;
	}

	public void setUserPassword(String userPassword) {
		this.userPassword = userPassword;
	}

	public Date getUserUpdateDate() {
		return this.userUpdateDate;
	}

	public void setUserUpdateDate(Date userUpdateDate) {
		this.userUpdateDate = userUpdateDate;
	}

}